package org.jsola.contract.web;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
import org.jsola.contract.dto.ContractCredentialAddDTO;
import org.jsola.contract.dto.ContractCredentialUpdateDTO;
import org.jsola.contract.query.ContractCredentialQuery;
import org.jsola.contract.vo.ContractCredentialListVO;
import org.jsola.contract.vo.ContractCredentialVO;
import org.jsola.core.Page;
import org.jsola.core.Result;

import java.util.List;

/**
 * 电子合同账号凭证
 *
 * @author JanusMix
 */
@Api(tags = "contract-电子合同账号凭证")
public interface IContractCredentialControllerAPI {

    /**
     * 新增电子合同账号凭证
     * @param contractCredentialAddDTO 电子合同账号凭证新增实体
     * @return 电子合同账号凭证展示对象
     */
    @ApiOperation(value = "新增电子合同账号凭证")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialAddDTO", dataType = "ContractCredentialAddDTO", value = "新增电子合同账号凭证", paramType = "body")
    })
    Result<ContractCredentialVO> save(ContractCredentialAddDTO contractCredentialAddDTO);


    /**
     * 修改电子合同账号凭证
     * @param contractCredentialUpdateDTO 电子合同账号凭证
     * @return 更新数量
     */
    @ApiOperation(value = "修改电子合同账号凭证")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialUpdateDTO", dataType = "ContractCredentialUpdateDTO", value = "修改电子合同账号凭证", paramType = "body")
    })
    Result<Integer> update(ContractCredentialUpdateDTO contractCredentialUpdateDTO);




    /**
     * 删除单个电子合同账号凭证，彻底删除
     * @param contractCredentialId 电子合同账号凭证id
     * @return 删除数量
     */
    @ApiOperation(value="删除单个电子合同账号凭证，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialId", dataType = "String", value = "电子合同账号凭证id", paramType = "path")
    })
    Result<Integer> delete(String contractCredentialId);


    /**
     * 批量删除电子合同账号凭证，彻底删除
     * @param contractCredentialIds 电子合同账号凭证id集合
     * @return 删除数量
     */
    @ApiOperation(value = "批量删除电子合同账号凭证，彻底删除")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialIds", dataType = "String[]", value = "电子合同账号凭证id数组", paramType = "body" ,allowMultiple = true)
    })
    Result<Integer> deleteBatch(String[] contractCredentialIds);


    /**
     * 根据电子合同账号凭证id查询电子合同账号凭证详情
     * @param contractCredentialId 电子合同账号凭证id
     * @return 电子合同账号凭证详情
     */
    @ApiOperation(value="根据电子合同账号凭证id查询电子合同账号凭证详情")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialId", dataType = "String", value = "电子合同账号凭证id", paramType = "path")
    })
    Result<ContractCredentialVO> findById(String contractCredentialId);


    /**
     * 查询电子合同账号凭证
     * @param contractCredentialQuery 电子合同账号凭证查询参数
     * @return page
     */
    @ApiOperation(value="查询电子合同账号凭证")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialQuery", dataType = "ContractCredentialQuery", value = "电子合同账号凭证查询参数", paramType = "query")
    })
    Result<List<ContractCredentialListVO>> listAll(ContractCredentialQuery contractCredentialQuery);


     /**
     * 分页查询电子合同账号凭证
     * @param contractCredentialQuery 电子合同账号凭证查询参数
     * @return page
     */
    @ApiOperation(value="分页查询电子合同账号凭证")
    @ApiImplicitParams({
            @ApiImplicitParam(name = "contractCredentialQuery", dataType = "ContractCredentialQuery", value = "电子合同账号凭证查询参数", paramType = "query")
    })
    Result<Page<ContractCredentialListVO>> page(ContractCredentialQuery contractCredentialQuery);

    /**
     * 查询电子合同账号凭证详情
     * @return 电子合同账号凭证详情
     */
    @ApiOperation(value="查询电子合同账号凭证详情")
    Result<ContractCredentialVO> select();
}

